#ifndef RTTIMERQUEUEORDEREDLIST_H
#define RTTIMERQUEUEORDEREDLIST_H

#include "RtTimerQueueBase.h"
#include <list>

class CRtTimerQueueOrderedList : public CRtTimerQueueBase  
{
public:
	CRtTimerQueueOrderedList(IRtObserver *aObserver);
	virtual ~CRtTimerQueueOrderedList();

protected:
	virtual int PushNode_l(const CNode &aPushNode);
	virtual int EraseNode_l(IRtTimerHandler *aEh);
	virtual int RePushNode_l(const CNode &aPushNode);
	virtual int PopFirstNode_l(CNode &aPopNode);
	virtual int GetEarliestTime_l(CRtTimeValue &aEarliest) const;

private:
	int EnsureSorted();

	typedef std::list<CNode> NodesType;
	NodesType m_Nodes;
};

#endif // !RTTIMERQUEUEORDEREDLIST_H
